<!-- 小组页面
 -->
<template>
  <div>
      <div class="header">
          <div class="hemain">
              <img src="../../images/icon.jpg" alt="" width="150px">
              <el-menu :default-active="activeIndex" class="el-menu-demo" background-color="rgba(0,0,0,0.5)"
               text-color="#fff" active-text-color="#ffd04b" mode="horizontal" @select="handleSelect">
                    <el-menu-item index="1">首页</el-menu-item>
                      <el-menu-item index="2">成员</el-menu-item>
              </el-menu>
              <div class="title">
                  <span id="group-title">广州人像摄影群</span><br>
                  <span id="group-intro">简介：广州人像爱好摄影师群</span>
                  <el-button style="left: 20px; bottom: -5px;">申请加入</el-button>
              </div>
          </div>
      </div>
      <div class="content">
          <group-index v-if="group"></group-index>
          <group-per v-else></group-per>
      </div>
  </div>
</template>

<script>
import GroupIndex from './oneGroupIndex.vue'
import GroupPer from './oneGroupPer.vue'
export default {
  data () {
    return {
           activeIndex: '2',
           group:false,
    };
  },
  components:{
      GroupIndex,
      GroupPer
  },

  methods: {
      handleSelect(key, keyPath) {
        this.group=!this.group
      }
  }
}

</script>
<style lang='scss' scoped>
.header{
    background-image: url('../../images/3.png');
    background-position: fixed;
    background-repeat: no-repeat;
    background-size:100% auto;
    height: 400px;
    .hemain{
        position:absolute;
        top: 340px;
        height: 62px;
        width:100%;
        padding:0 200px;
        background-color:rgba(0,0,0,0.7);
        img{
            position:absolute;
            bottom: 0;
        }
        .el-menu-demo{
            position: absolute;
            bottom:0;
            margin-left:165px;
            
        }
    }
    .title{
        position:absolute;
        bottom: 70px;
        left: 365px;
        #group-title{
                font-size: 30px;
    color: #303133;
    letter-spacing: 5px;
    font-weight: bold;
        }
        #group-intro{
                font-size: 20px;
    letter-spacing: 3px;
    line-height: 50px;
    color: #060505;
        }
    }
}
.content{
    position: relative;
    width:80%;
    margin:100px 200px;
}
</style>